package com.qfedu.openplateform.manager.service.impl;

import com.qfedu.openplateform.manager.dao.CustomerMapper;
import com.qfedu.openplateform.manager.dao.RechargeMapper;
import com.qfedu.openplateform.manager.entity.Customer;
import com.qfedu.openplateform.manager.entity.Recharge;
import com.qfedu.openplateform.manager.service.RechargeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @author LLFZH
 * @date 2021/10/27 17:07
 * @className RechargeServiceImpl
 * @description ：充值管理服务层实现类
 */
@Service
@Transactional
public class RechargeServiceImpl implements RechargeService {

    @Autowired
    private RechargeMapper rechargeMapper;

    @Autowired
    private CustomerMapper customerMapper;

    @Override
    public List<Recharge> findAllRecharge() {
        return rechargeMapper.findAllRecharge();
    }

    @Override
    public void deleteRechargeById(Integer[] ids) {
        rechargeMapper.deleteRechargeById(ids);
    }

    @Override
    public void updateRecharge(Recharge recharge) {
        rechargeMapper.updateRecharge(recharge);

    }

    @Override
    public void addRecharge(Recharge recharge) {
        rechargeMapper.addRecharge(recharge);
    }

//    @Override
//    public List<Integer> getAllCustomerId() {
//        return customerMapper.getAllCustomerId();
//    }

}
